package com.ibeetl.admin.console.web.query;

import java.util.Date;

import org.apache.commons.lang3.StringUtils;

import com.ibeetl.admin.core.annotation.Query;
import com.ibeetl.admin.core.util.Tool;
import com.ibeetl.admin.core.util.enums.CoreDictType;
import com.ibeetl.admin.core.web.query.PageParam;

public class PayOrderQuery extends PageParam {

	@Query(name="订单号",display=true)
	private String id;
	
	@Query(name="微信昵称",display=true,fuzzy=true)
	private String nickName;

	/*
	 * // 交易类型
	 * 
	 * @Query(name="交易类型",display=true,type=Query.TYPE_DICT,dict=CoreDictType.
	 * TRADE_TYPE) private String tradeType;
	 */
	
	// 支付类型
	@Query(name="支付类型",display=true,type=Query.TYPE_DICT,dict=CoreDictType.PAY_TYPE)
	private String type;
	
	//支付时间
	@Query(name="支付时间",display=true,type=Query.TYPE_DATE_BETWEEN)
	private String requestTimeRange;
	private Date requestTimeMin;
	private Date requestTimeMax;

	// 订单状态
	@Query(name="支付状态",display=true,type=Query.TYPE_DICT,dict=CoreDictType.ORDER_STATUS)
	private String orderStatus;


    public String getRequestTimeRange() {
		return requestTimeRange;
	}
	public void setRequestTimeRange(String requestTimeRange) {
		this.requestTimeRange = requestTimeRange;
		if(StringUtils.isEmpty(requestTimeRange)) {
			return ;
		}
		Date[] ds = Tool.parseDataRange(requestTimeRange);
		this.requestTimeMin=ds[0];
		this.requestTimeMax =ds[1];
	}
	public String getNickName() {
		return nickName;
	}
	public void setNickName(String nickName) {
		this.nickName = nickName;
	}

	public String getId() {
		return id;
	}
	public void setId(String id) {
		this.id = id;
	}

	public String getType() {
		return type;
	}
	public void setType(String type) {
		this.type = type;
	}
	public Date getRequestTimeMin() {
		return requestTimeMin;
	}
	public void setRequestTimeMin(Date requestTimeMin) {
		this.requestTimeMin = requestTimeMin;
	}
	public Date getRequestTimeMax() {
		return requestTimeMax;
	}
	public void setRequestTimeMax(Date requestTimeMax) {
		this.requestTimeMax = requestTimeMax;
	}
	public String getOrderStatus() {
		return orderStatus;
	}
	public void setOrderStatus(String orderStatus) {
		this.orderStatus = orderStatus;
	}


}
